package com.projects.api.common.model.result;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.List;

/**
 * @author zhangzhenfu
 * @Description
 * @date 2022/5/15 0015 15:49
 */
@Data
public class ResultPage<T> extends ResultMsg<List<T>> {

    @ApiModelProperty(value = "当前页码")
    private Integer pageNum;

    @ApiModelProperty(value = " 每页数量")
    private Integer pageSize;

    @ApiModelProperty(value = "总页数")
    private Integer totalPage;

    @ApiModelProperty(value = "总条数")
    private Long total;

    @ApiModelProperty(value = "是否有前一页")
    private boolean hasPreviousPage = false;

    @ApiModelProperty(value = "是否有下一页")
    private boolean hasNextPage = false;

    public ResultPage() {
        super(ResultConstant.SUCCESS);
    }

}
